Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]Support add/drop field for struct column(part2) #46619

Merged
merged 7 commits into from
Jun 19, 2024

Conversation

sevev
Copy link
Contributor

@sevev sevev commented Jun 4, 2024

Why I'm doing:

It is the second pr to support add/drop field for struct column.

What I'm doing:

The main changes in this PR are two fold:

  1. Add the new syntax for add/drop field.
  2. Support analyze add/drop field.

This pr doesn't fully implement this feature yet, and will throw not support exception when executed.

Fixes #46452

What type of PR is this:

  • BugFix
  • Feature
  • Enhancement
  • Refactor
  • UT
  • Doc
  • Tool

Does this PR entail a change in behavior?

  • Yes, this PR will result in a change in behavior.
  • No, this PR will not result in a change in behavior.

If yes, please specify the type of change:

  • Interface/UI changes: syntax, type conversion, expression evaluation, display information
  • Parameter changes: default values, similar parameters but with different default values
  • Policy changes: use new policy to replace old one, functionality automatically enabled
  • Feature removed
  • Miscellaneous: upgrade & downgrade compatibility, etc.

Checklist:

  • I have added test cases for my bug fix or my new feature
  • This pr needs user documentation (for new or modified features or behaviors)
    • I have added documentation for my new feature or new function
  • This is a backport pr

Bugfix cherry-pick branch check:

  • I have checked the version labels which the pr will be auto-backported to the target branch
    • 3.3
    • 3.2
    • 3.1
    • 3.0
    • 2.5

@sevev sevev requested review from a team as code owners June 4, 2024 07:18
@wyb wyb requested a review from luohaha June 7, 2024 02:10
@sevev sevev force-pushed the support_add_drop_field_part2 branch from 0003760 to fa7012a Compare June 13, 2024 06:34
@sevev sevev requested review from wyb and packy92 June 13, 2024 06:36
@sevev sevev force-pushed the support_add_drop_field_part2 branch from fa7012a to 093955b Compare June 13, 2024 07:40
wyb
wyb previously approved these changes Jun 13, 2024
gengjun-git
gengjun-git previously approved these changes Jun 17, 2024
packy92
packy92 previously approved these changes Jun 17, 2024
Signed-off-by: zhangqiang <[email protected]>
Signed-off-by: zhangqiang <[email protected]>
Signed-off-by: zhangqiang <[email protected]>
Signed-off-by: zhangqiang <[email protected]>
Signed-off-by: sevev <[email protected]>
@sevev sevev dismissed stale reviews from gengjun-git and wyb via 76a28a8 June 19, 2024 02:18
@sevev sevev force-pushed the support_add_drop_field_part2 branch from c66d206 to 76a28a8 Compare June 19, 2024 02:18
Copy link

sonarcloud bot commented Jun 19, 2024

Quality Gate Failed Quality Gate failed

Failed conditions
5.0% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

@HangyuanLiu HangyuanLiu self-assigned this Jun 19, 2024
Copy link

[FE Incremental Coverage Report]

pass : 87 / 107 (81.31%)

file detail

path covered_line new_line coverage not_covered_line_detail
🔵 com/starrocks/sql/ast/AstVisitor.java 0 2 00.00% [1131, 1135]
🔵 com/starrocks/connector/iceberg/IcebergAlterTableExecutor.java 0 4 00.00% [199, 200, 205, 206]
🔵 com/starrocks/alter/AlterJobExecutor.java 0 4 00.00% [238, 239, 244, 245]
🔵 com/starrocks/sql/analyzer/AlterTableClauseAnalyzer.java 20 24 83.33% [720, 724, 741, 745]
🔵 com/starrocks/sql/ast/StructFieldDesc.java 47 53 88.68% [72, 95, 138, 143, 144, 150]
🔵 com/starrocks/sql/ast/AddFieldClause.java 7 7 100.00% []
🔵 com/starrocks/sql/ast/DropFieldClause.java 9 9 100.00% []
🔵 com/starrocks/alter/SchemaChangeHandler.java 4 4 100.00% []

Copy link

[BE Incremental Coverage Report]

pass : 0 / 0 (0%)

@sevev sevev merged commit 93f333e into StarRocks:main Jun 19, 2024
54 of 55 checks passed
@sevev
Copy link
Contributor Author

sevev commented Jun 19, 2024

@mergify backport branch-3.3

Copy link
Contributor

mergify bot commented Jun 19, 2024

backport branch-3.3

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jun 19, 2024
## Why I'm doing:
It is the second pr to support add/drop field for struct column.

## What I'm doing:
The main changes in this PR are two fold:

1. Add the new syntax for add/drop field.
2. Support analyze add/drop field.

This pr doesn't fully implement this feature yet, and will throw not support exception when executed.

Fixes #46452

Signed-off-by: zhangqiang <[email protected]>
(cherry picked from commit 93f333e)

# Conflicts:
#	fe/fe-core/src/main/java/com/starrocks/sql/analyzer/AlterTableClauseVisitor.java
#	fe/fe-core/src/main/java/com/starrocks/sql/parser/StarRocksLex.g4
happut pushed a commit to happut/starrocks that referenced this pull request Jun 26, 2024
…6619)

## Why I'm doing:
It is the second pr to support add/drop field for struct column. 

## What I'm doing:
The main changes in this PR are two fold:

1. Add the new syntax for add/drop field.
2. Support analyze add/drop field.

This pr doesn't fully implement this feature yet, and will throw not support exception when executed.

Fixes StarRocks#46452

Signed-off-by: zhangqiang <[email protected]>
@sevev
Copy link
Contributor Author

sevev commented Jun 26, 2024

@mergify backport branch-3.3

Copy link
Contributor

mergify bot commented Jun 26, 2024

backport branch-3.3

✅ Backports have been created

wanpengfei-git pushed a commit that referenced this pull request Jun 26, 2024
@sevev
Copy link
Contributor Author

sevev commented Jun 27, 2024

@mergify backport branch-3.2

Copy link
Contributor

mergify bot commented Jun 27, 2024

backport branch-3.2

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jun 27, 2024
## Why I'm doing:
It is the second pr to support add/drop field for struct column.

## What I'm doing:
The main changes in this PR are two fold:

1. Add the new syntax for add/drop field.
2. Support analyze add/drop field.

This pr doesn't fully implement this feature yet, and will throw not support exception when executed.

Fixes #46452

Signed-off-by: zhangqiang <[email protected]>
(cherry picked from commit 93f333e)

# Conflicts:
#	fe/fe-core/src/main/java/com/starrocks/connector/iceberg/IcebergAlterTableExecutor.java
#	fe/fe-core/src/main/java/com/starrocks/sql/analyzer/AlterTableClauseVisitor.java
#	fe/fe-core/src/main/java/com/starrocks/sql/parser/AstBuilder.java
#	fe/fe-core/src/main/java/com/starrocks/sql/parser/StarRocks.g4
#	fe/fe-core/src/main/java/com/starrocks/sql/parser/StarRocksLex.g4
wanpengfei-git pushed a commit that referenced this pull request Jun 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support Add/drop Field for struct column
7 participants